package robocup.component.speechacts.coachlanguage;

import java.util.LinkedList;

public class Definerset {

  private String              name   = "";

  private LinkedList<Integer> idList = new LinkedList<Integer>();

  public void addId(final int id) {

    this.idList.add(id);
  }

  public LinkedList<Integer> getIdList() {

    return this.idList;
  }

  public void setIdList(final LinkedList<Integer> idList) {

    this.idList = idList;
  }

  public String getName() {

    return this.name;
  }

  public void setName(final String name) {

    this.name = name;
  }

  private String listToString() {

    final StringBuffer buf = new StringBuffer();

    for (final int i : this.idList) {
      buf.append(" " + i);
    }
    return buf.toString();
  }

  @Override
  public String toString() {

    return "(definerset " + this.name + this.listToString() + ")";
  }

}
